'use strict';
var rank_asc = function(collection){
    var a=collection.length;
    for(let i=0;i<a;i++){
       for(let j=0;j<a-1-i;j++){
           if(collection[j]<collection[j+1]){
             var temp=collection[j+1];
             collection[j+1]=collection[j];
             collection[j]=temp;
           }
      }
    }
console.log(collection);
return collection;// return [6,5,4,3,2];
};

module.exports = rank_asc;
